//
//  TextAreaCell.swift
//  travel
//
//  Created by tong on 16/6/26.
//  Copyright © 2016年 zhuxietong. All rights reserved.
//

import UIKit
import Eelay


open class TextAreaCell<Line:LineHeight>: JoTableCell {
    
    public var textV = TextAreaField()
    open override func addLayoutRules() {

        contentView.eelay = [
            [textV,[ee.T.L.B.R,[20,16,-30,-16]],"\(Line.height)"],
        ]
        
//        textV.bsui.corner4.background(color: _table_bk_color)
        
        
    }
    
    open override func mo_model_reload() {
        
//        contentView.fillData(model: mo.model)
        
        if let f = DataNode<NSMutableDictionary>.path(node: "\(FK.field)", mo.model)
        {
            textV.mo.model = f
        }
        else
        {
            if let f = DataNode<NSMutableDictionary>.path(node: "\(FK.fields).0", mo.model)
            {
                textV.mo.model = f
            }
        }
        textV.valueT.bsui.background(color: UIColor.table_bg_color)
    }
    
}
